package com.wkbb.socket;

import com.wkbb.common.handler.JsonUtil;
import lombok.Data;

import java.io.Serializable;

@Data
public class SocketAction implements Serializable {
    private String action;
    private String content;
    private Object data;

    public String dataJson() {
        if (data != null){
            return JsonUtil.objectToJson(data);
        }
        return null;
    }

}